package projsa.reservation;

import projsa.modelsa.TransUtils;

import java.util.HashMap;
import java.util.LinkedList;
import java.util.List;
import java.util.Map;

public class CityHours {

    private static Map<String, List<Integer>> map = new HashMap<String, List<Integer>>();

    public static List<Integer> getHoursForCity(final String city) {
        return map.get(city);
    }


    static {
        {
            final List<Integer> integers = new LinkedList<Integer>();
            for (int i = 0; i < 16; i++) {
                integers.add(TransUtils.toMinuteOfDay(6 + i, 40));
            }
            map.put(CityConstants.PRAHA_DEJVICKA, integers);
        }

        {
            final List<Integer> integers = new LinkedList<Integer>();
            for (int i = 0; i < 8; i++) {
                integers.add(TransUtils.toMinuteOfDay(5 + i * 2, 25));
            }
            map.put(CityConstants.SOKOLOV, integers);
        }


        {
            final List<Integer> integers = new LinkedList<Integer>();
            for (int i = 0; i < 18; i++) {
                integers.add(TransUtils.toMinuteOfDay(5 + i, 0));
            }
            map.put(CityConstants.KARLOVY_VARY, integers);
        }
    }

}
